package com.leetroll.api.service;

import com.leetroll.common.entity.Order;
import com.leetroll.common.vo.OrderDetailVO;
import com.leetroll.common.vo.OrderVO;

import java.util.List;

public interface OrderService extends SuperService<Order> {
    List<OrderVO> listByUserId(Long userId);

    List<OrderVO> listByUserAndStatus(Long userId, String status);

    Order getByBatchCode(String batchCode);

    Order addOrder(Long userId, List<OrderDetailVO> cartItemVOS);

    boolean paySuccess(String outTradeNo, String payCode, String payTime);

    Order updateOrder(Order order);

    boolean checkIfUserOwnItem(Long userId, Integer itemId);
}
